﻿using System.Collections.Generic;

namespace com.binance.client.model.enums
{

	public sealed class TransferFuturesDirection
	{

	  /// <summary>
	  /// FUTURES_TO_PRO,PRO_TO_FUTURES
	  /// </summary>
	  public static readonly TransferFuturesDirection FUTURES_TO_PRO = new TransferFuturesDirection("FUTURES_TO_PRO", InnerEnum.FUTURES_TO_PRO, "futures-to-pro");
	  public static readonly TransferFuturesDirection PRO_TO_FUTURES = new TransferFuturesDirection("PRO_TO_FUTURES", InnerEnum.PRO_TO_FUTURES, "pro-to-futures");

	  private static readonly IList<TransferFuturesDirection> valueList = new List<TransferFuturesDirection>();

	  static TransferFuturesDirection()
	  {
		  valueList.Add(FUTURES_TO_PRO);
		  valueList.Add(PRO_TO_FUTURES);
	  }

	  public enum InnerEnum
	  {
		  FUTURES_TO_PRO,
		  PRO_TO_FUTURES
	  }

	  public readonly InnerEnum innerEnumValue;
	  private readonly string nameValue;
	  private readonly int ordinalValue;
	  private static int nextOrdinal = 0;

	  private string direction;

	  internal TransferFuturesDirection(string name, InnerEnum innerEnum, string direction)
	  {
		this.direction = direction;

		  nameValue = name;
		  ordinalValue = nextOrdinal++;
		  innerEnumValue = innerEnum;
	  }

	  public string Direction
	  {
		  get
		  {
			return direction;
		  }
	  }

	  public static TransferFuturesDirection find(string direction)
	  {
		foreach (TransferFuturesDirection d in TransferFuturesDirection.values())
		{
		  if (d.Direction.Equals(direction))
		  {
			return d;
		  }
		}
		return null;
	  }

		public static IList<TransferFuturesDirection> values()
		{
			return valueList;
		}

		public int ordinal()
		{
			return ordinalValue;
		}

		public override string ToString()
		{
			return nameValue;
		}

		public static TransferFuturesDirection valueOf(string name)
		{
			foreach (TransferFuturesDirection enumInstance in TransferFuturesDirection.valueList)
			{
				if (enumInstance.nameValue == name)
				{
					return enumInstance;
				}
			}
			throw new System.ArgumentException(name);
		}
	}

}